home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / abrows1a / frmmain.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1999-09-18  |  7.0 KB  |  222 lines

  1. VERSION 5.00
  2. Object = "{831FDD16-0C5C-11D2-A9FC-0000F8754DA1}#2.0#0"; "MSCOMCTL.OCX"
  3. Begin VB.Form frmMain 
  4.    Caption         =   "Andrew's Web Browser"
  5.    ClientHeight    =   2220
  6.    ClientLeft      =   165
  7.    ClientTop       =   450
  8.    ClientWidth     =   4680
  9.    LinkTopic       =   "Form1"
  10.    ScaleHeight     =   2220
  11.    ScaleWidth      =   4680
  12.    StartUpPosition =   1  'CenterOwner
  13.    Begin VB.CommandButton Command4 
  14.       Caption         =   "HTML editor"
  15.       Height          =   495
  16.       Left            =   1800
  17.       TabIndex        =   5
  18.       Top             =   960
  19.       Width           =   1215
  20.    End
  21.    Begin VB.PictureBox Picture1 
  22.       BorderStyle     =   0  'None
  23.       Height          =   1815
  24.       Left            =   0
  25.       Picture         =   "frmMain.frx":0000
  26.       ScaleHeight     =   1815
  27.       ScaleWidth      =   1695
  28.       TabIndex        =   4
  29.       Top             =   0
  30.       Width           =   1695
  31.    End
  32.    Begin VB.CommandButton Command3 
  33.       Caption         =   "&Exit"
  34.       Height          =   495
  35.       Left            =   3240
  36.       TabIndex        =   3
  37.       Top             =   960
  38.       Width           =   1215
  39.    End
  40.    Begin VB.CommandButton Command2 
  41.       Caption         =   "&Contact Information"
  42.       Height          =   495
  43.       Left            =   3240
  44.       TabIndex        =   2
  45.       Top             =   240
  46.       Width           =   1215
  47.    End
  48.    Begin VB.CommandButton Command1 
  49.       Caption         =   "&Web Browser"
  50.       Height          =   495
  51.       Left            =   1800
  52.       TabIndex        =   1
  53.       Top             =   240
  54.       Width           =   1215
  55.    End
  56.    Begin MSComctlLib.StatusBar sbStatusBar 
  57.       Align           =   2  'Align Bottom
  58.       Height          =   270
  59.       Left            =   0
  60.       TabIndex        =   0
  61.       Top             =   1950
  62.       Width           =   4680
  63.       _ExtentX        =   8255
  64.       _ExtentY        =   476
  65.       _Version        =   393216
  66.       BeginProperty Panels {8E3867A5-8586-11D1-B16A-00C0F0283628} 
  67.          NumPanels       =   3
  68.          BeginProperty Panel1 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  69.             AutoSize        =   1
  70.             Object.Width           =   2619
  71.             Text            =   "Status"
  72.             TextSave        =   "Status"
  73.          EndProperty
  74.          BeginProperty Panel2 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  75.             Style           =   6
  76.             AutoSize        =   2
  77.             TextSave        =   "18/09/99"
  78.          EndProperty
  79.          BeginProperty Panel3 {8E3867AB-8586-11D1-B16A-00C0F0283628} 
  80.             Style           =   5
  81.             AutoSize        =   2
  82.             TextSave        =   "14:07"
  83.          EndProperty
  84.       EndProperty
  85.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  86.          Name            =   "Comic Sans MS"
  87.          Size            =   8.25
  88.          Charset         =   0
  89.          Weight          =   400
  90.          Underline       =   0   'False
  91.          Italic          =   0   'False
  92.          Strikethrough   =   0   'False
  93.       EndProperty
  94.    End
  95.    Begin VB.Menu mnuFile 
  96.       Caption         =   "&File"
  97.       Begin VB.Menu mnuFileBar5 
  98.          Caption         =   "-"
  99.          Visible         =   0   'False
  100.       End
  101.       Begin VB.Menu mnuFileExit 
  102.          Caption         =   "E&xit"
  103.       End
  104.    End
  105.    Begin VB.Menu mnuView 
  106.       Caption         =   "&View"
  107.       Begin VB.Menu mnuViewStatusBar 
  108.          Caption         =   "Status &Bar"
  109.          Checked         =   -1  'True
  110.       End
  111.       Begin VB.Menu mnuViewBar0 
  112.          Caption         =   "-"
  113.       End
  114.       Begin VB.Menu mnuViewWebBrowser 
  115.          Caption         =   "&Web Browser"
  116.       End
  117.       Begin VB.Menu html 
  118.          Caption         =   "&HTML Editor"
  119.       End
  120.       Begin VB.Menu Contact 
  121.          Caption         =   "&Contact"
  122.       End
  123.    End
  124.    Begin VB.Menu mnuHelp 
  125.       Caption         =   "&Help"
  126.       Begin VB.Menu mnuHelpContents 
  127.          Caption         =   "&Contents"
  128.       End
  129.       Begin VB.Menu mnuHelpSearchForHelpOn 
  130.          Caption         =   "&Search For Help On..."
  131.       End
  132.       Begin VB.Menu mnuHelpBar0 
  133.          Caption         =   "-"
  134.       End
  135.       Begin VB.Menu mnuHelpAbout 
  136.          Caption         =   "&About "
  137.       End
  138.    End
  139. Attribute VB_Name = "frmMain"
  140. Attribute VB_GlobalNameSpace = False
  141. Attribute VB_Creatable = False
  142. Attribute VB_PredeclaredId = True
  143. Attribute VB_Exposed = False
  144. Private Declare Function OSWinHelp% Lib "user32" Alias "WinHelpA" (ByVal hwnd&, ByVal HelpFile$, ByVal wCommand%, dwData As Any)
  145. Private Sub Command1_Click()
  146.     frmBrowser.Show , Me
  147. End Sub
  148. Private Sub Command2_Click()
  149.     frmHTML.Show , Me
  150. End Sub
  151. Private Sub Command3_Click()
  152.     'unload the form
  153.     Unload Me
  154. End Sub
  155. Private Sub Command4_Click()
  156.     frmEditor.Show , Me
  157. End Sub
  158. Private Sub Contact_Click()
  159.     frmHTML.Show , Me
  160. End Sub
  161. Private Sub Form_Load()
  162.     Me.Left = GetSetting(App.Title, "Settings", "MainLeft", 1000)
  163.     Me.Top = GetSetting(App.Title, "Settings", "MainTop", 1000)
  164.     Me.Width = GetSetting(App.Title, "Settings", "MainWidth", 6500)
  165.     Me.Height = GetSetting(App.Title, "Settings", "MainHeight", 6500)
  166. End Sub
  167. Private Sub Form_Unload(Cancel As Integer)
  168.     Dim i As Integer
  169.     For i = Forms.Count - 1 To 1 Step -1
  170.         Unload Forms(i)
  171.     Next
  172.     If Me.WindowState <> vbMinimized Then
  173.         SaveSetting App.Title, "Settings", "MainLeft", Me.Left
  174.         SaveSetting App.Title, "Settings", "MainTop", Me.Top
  175.         SaveSetting App.Title, "Settings", "MainWidth", Me.Width
  176.         SaveSetting App.Title, "Settings", "MainHeight", Me.Height
  177.     End If
  178. End Sub
  179. Private Sub html_Click()
  180.     frmEditor.Show vbModal, Me
  181. End Sub
  182. Private Sub mnuHelpAbout_Click()
  183.     frmAbout.Show vbModal, Me
  184. End Sub
  185. Private Sub mnuHelpSearchForHelpOn_Click()
  186.     Dim nRet As Integer
  187.     If Len(App.HelpFile) = 0 Then
  188.         MsgBox "There is no Help file, god damn it!", vbInformation, Me.Caption
  189.     Else
  190.         On Error Resume Next
  191.         nRet = OSWinHelp(Me.hwnd, App.HelpFile, 261, 0)
  192.         If Err Then
  193.             MsgBox Err.Description
  194.         End If
  195.     End If
  196. End Sub
  197. Private Sub mnuHelpContents_Click()
  198.     Dim nRet As Integer
  199.     If Len(App.HelpFile) = 0 Then
  200.         MsgBox "There is no Help file, god damn it!", vbInformation, Me.Caption
  201.     Else
  202.         On Error Resume Next
  203.         nRet = OSWinHelp(Me.hwnd, App.HelpFile, 3, 0)
  204.         If Err Then
  205.             MsgBox Err.Description
  206.         End If
  207.     End If
  208. End Sub
  209. Private Sub mnuViewWebBrowser_Click()
  210.     Dim frmB As New frmBrowser
  211.     StartingAddress = "Enter URL here..."
  212.     frmB.Show
  213. End Sub
  214. Private Sub mnuViewStatusBar_Click()
  215.     mnuViewStatusBar.Checked = Not mnuViewStatusBar.Checked
  216.     sbStatusBar.Visible = mnuViewStatusBar.Checked
  217. End Sub
  218. Private Sub mnuFileExit_Click()
  219.     Unload Me
  220. End Sub
  221. 'This was made by that guy, Andrew Madden :0)
  222.